broadway: Fix leftover dom modification not using display_commands
authorAlexander Larsson <alexl@redhat.com>
Wed, 27 Mar 2019 13:21:28 +0000 (14:21 +0100)
committerAlexander Larsson <alexl@redhat.com>
Wed, 27 Mar 2019 13:21:28 +0000 (14:21 +0100)
gdk/broadway/broadway.js

index 00c341c393cdcc2c85fcf52cebd49ef2a52e3188..c6e537c9093de8487527a644a7110bedcea1e43a 100644 (file)
@@ -755,7 +755,7 @@ TransformNodes.prototype.insertNode = function(parent, posInParent, oldNode)
 
             /* Remove children that are after the new length */
             for (i = oldChildren.length - 1; i > len - 1; i--)
-                oldNode.removeChild(oldChildren[i]);
+                this.display_commands.push([DISPLAY_OP_DELETE_NODE, oldChildren[i]]);
 
             /* NOTE: No need to modify the parent, we're keeping this node as is */
             newNode = null;